home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 120
/
Vol 120.iso
/
games
/
battlefi.swf
/
scripts
/
frame_636
/
PlaceObject2_17_2214
/
CLIPACTIONRECORD onClipEvent(enterFrame).as
next >
Wrap
Text File
|
2010-11-09
|
605b
|
30 lines
onClipEvent(enterFrame){
a = total / 5 * 4;
b = total / 5 * 3;
c = total / 5 * 2;
d = total / 5;
if(this._xscale <= 0)
{
this._xscale = 0;
}
percent = remaining / total * 100;
this._xscale = percent;
_root.rem = remaining;
if(remaining < a && remaining > b)
{
_root.castle.gotoAndStop(2);
}
if(remaining < b && remaining > c)
{
_root.castle.gotoAndStop(3);
}
if(remaining < c && remaining > d)
{
_root.castle.gotoAndStop(4);
}
if(remaining < d)
{
_root.castle.gotoAndStop(5);
}
}